import Vue from 'vue'
import Vuex from 'vuex'

import state from './state.js'
import getters from './getters.js'
import mutations from './mutations.js'
import actions from './actions.js'
import modules from './modules.js'
 
Vue.use(Vuex)


/**
 * @前言
 * getter 和 action 的意义是为了做 统一处理，类似于 computed，单个属性的赋值和获取直接操作即可。
 * 
 */


const store = new Vuex.Store({
  state,
  getters,
  mutations,
  actions,
  modules
})

export default store
